module.exports = {
    lintOnSave: false,
    css: {
        sourceMap: false,
        loaderOptions: {
            sass: {
                additionalData: `@import "src/assets/styles/variable.scss";@import "src/assets/styles/mixin.scss";`,
            },
        },
    },
    devServer: {
        host: 'localhost',
        https: false,
        hotOnly: false,
        proxy: {
            //反向代理的方式解决跨域
            "/api": {
                target: "http://47.96.0.211:9000", //目标域名
                changeOrigin: true, //是否改变域名
                pathRewrite: {
                    //以什么开头
                    "^/api": "",
                },
            },
            "/data": {
                target: "http://118.31.109.254:8088", //目标域名
                changeOrigin: true, //是否改变域名
                pathRewrite: {
                    //以什么开头
                    "^/data": "",
                },
            },
            "/douban": {
                target: "http://39.96.84.220:9000", //目标域名
                changeOrigin: true, //是否改变域名
                pathRewrite: {
                    //以什么开头
                    "^/douban": "",
                },
            },
        }, // 设置代理
        before: (app) => {},
    },
};
